// 列名字典
const colNameDictList = [
  { name: 'ID', code: 'id' },
  { name: 'APPid', code: 'APPid' },
  { name: '产品名称', code: 'productName' },
  { name: '最后修改时间', code: 'zTableUpdateTime' },
  { name: '关键词数量', code: 'subTableCount' },
  { name: '进度', code: 'TotalSchedule' },
  { name: '上限', code: 'TotalUpperLimit' },
  { name: '百分比', code: 'percentage' },
  { name: '开始时间', code: 'startTime' },
  { name: '结束时间', code: 'endTime' },
  { name: '是否匀速', code: 'isConstantSpeed' },
  { name: '屏蔽越狱', code: 'maskJailbreak' },
  { name: '时长', code: 'duration' },
  { name: '点击间隔', code: 'clickInterval' },
  { name: 'VPN', code: 'VPN' },
  { name: '接口id', code: 'portId' },
  { name: '回调任务', code: 'callbackTask' },
  { name: 'APPBID', code: 'APPBID' },
  { name: '跳转id', code: 'skipId' },
  { name: '搜索名称', code: 'searchName' },
  { name: '应用列表名称', code: 'applicationListName' },
  { name: '客户信息来源', code: 'customerInformationSource' },
  { name: '防作弊检测', code: 'antiCheatDetection' },
  { name: '绕过版本', code: 'bypassVersion' },
  { name: '输出参数', code: 'outputParam' },
  { name: '备注1', code: 'remark1' },
  { name: '备注2', code: 'remark2' },
  { name: '备注3', code: 'remark3' },
  { name: '备注4', code: 'remark4' },
  { name: '备注5', code: 'remark5' },
  { name: '更新时间', code: 'updateTime' },
  { name: '创建时间', code: 'createTime' }
]

// 开关
const switchList = [
  { name: '开', code: '开' },
  { name: '关', code: '关' }
]

// 获取指定数据的Label   type：配置数据变量名
function getAssignDataLabel(v, type) {
  // console.log('v, type', v, type)
  // eslint-disable-next-line no-eval
  const obj = eval(type).find(o => o.code === v)
  // console.log('obj', obj)
  if (obj) {
    return obj.name
  }
}

export {
  colNameDictList,
  switchList,
  getAssignDataLabel
}
